#!/bin/bash
if(test -L $0) then auxlink=`ls -l $0 | sed 's/^[^>]*-> //g'`; M_HOME=`dirname $auxlink`/; else M_HOME=`dirname $0`/; fi; cd $M_HOME
[ -f ../files/20-names.rules ] || { echo ../files/20-names.rules not found.; exit 1; }
. ../before || exit 1
sb2 ./configure --prefix=/usr --exec-prefix= --sysconfdir=/etc
sb2 make
sb2 make DESTDIR=$ROOTFS/ install
popd
[ -d $ROOTFS/lib/firmware ] || mkdir $ROOTFS/lib/firmware
[ -d $ROOTFS/etc/udev/rules.d/ ] || mkdir -p $ROOTFS/etc/udev/rules.d/
cp ../files/20-names.rules $ROOTFS/etc/udev/rules.d/
touch $ROOTFS/.`basename $0`

